             package com.java.diagnostics.visualizer.recommender.realtime;
             
             import com.java.diagnostics.visualizer.data.AggregateData;
             import com.java.diagnostics.visualizer.data.DataPoint;
             import com.java.diagnostics.visualizer.data.TupleData;
             import com.java.diagnostics.visualizer.recommender.Recommendation;
             import com.java.diagnostics.visualizer.recommender.RecommendationBase;
             import com.java.diagnostics.visualizer.recommender.util.RecommendationLabels;
             
             public class CalculateCollectionCounts
               extends RecommendationBase
               implements Recommendation
             {
               public void recommend(AggregateData data)
               {
                 String gcMode = (String)getGCMode(data);
                 if ("metronome".equalsIgnoreCase(gcMode)) {
                   TupleData synchGCDurations = data
                     .getTupleData("WRTLabels.synch.gc.durations");
                   if (synchGCDurations != null) {
                     DataPoint[] points = synchGCDurations.getDataPoints();
                     if (points != null) {
                       int synchGCCount = points.length;
                       addToQuantumSummary(data, 
                         RecommendationLabels.SYNCH_GC_COUNT, 
                         Integer.valueOf(synchGCCount));
                     }
                   }
                 }
               }
             }


